home *** CD-ROM | disk | FTP | other *** search
/ Softwarová Záchrana 3 / Softwarova-zachrana-3.bin / Xteq X-Setup / xqdcXSP-Setup-EN.exe / {app} / plugins / XQ Win2K Phantom Devs.xpl < prev    next >
Text File  |  2001-12-09  |  1KB  |  52 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 6.0"
  2. "TYPE"="6"
  3. "COUNT"="1"
  4. "UIPATH"="Hardware\System Settings"
  5. "NAME"="Windows Phantom Devices"
  6. "OSVERSION"="0001011"
  7. "VERSION"="2.03"
  8. "LANGUAGE"="VBScript"
  9. "TEXT 1"="Show phantom devices"
  10. "DESCRIPTION 1"="By default, the Device Manager (devmgmt.msc) does not show so called "Phantom Devices" (Devices that have drivers installed but are currently not connected to the system)."
  11. "DESCRIPTION 2"="By activating this option, the Device Manager will also show "Phantom Devices"."
  12. "AUTHOR"="Xteq Systems"
  13. "CONTACTURL"="http://www.xteq.com"
  14. "COPYRIGHT"="Copyright ⌐ Xteq Systems - All Rights Reserved"
  15. "COMMENT 1"="none, so far :-)"
  16.  
  17.  
  18. 'Declaration of some constants
  19. sP="HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Environment\DEVMGR_SHOW_NONPRESENT_DEVICES"
  20.  
  21.  
  22. 'Called when the Plugin is started
  23. Sub Plugin_Initialize
  24.  if RegValueExists(sP)=false then
  25.     SetUIElement 1,false
  26.  else
  27.     if RegReadValue(sP)="1" then
  28.        SetUIElement 1,true
  29.     end if
  30.  end if
  31.  
  32. End Sub
  33.  
  34.  
  35. 'Called when the Plugin should apply the changes
  36. Sub Plugin_Apply(ElementIndex,ElementSubIndex)
  37.  if GetUIElement(1)=true then
  38.     Call RegWriteValue(sP,"1",1)
  39.  else
  40.     if RegValueExists(sP)=true then
  41.        Call RegDeleteValue(sP)
  42.     end if
  43.  end if
  44.  
  45.  Call Restart()
  46. End Sub
  47.  
  48. 'Called when the Plugin is about to be removed from memory
  49. Sub Plugin_Terminate
  50. End Sub
  51.  
  52.